import sys
import json

params = json.loads(sys.argv[1])
current_phase = params['current_phase']
if len(current_phase) == 0:
	phase_id = "build_phase"
else:
	phase_id = "build_phase_invalid"
ofile = file('misptemp','wt')
ofile.write('''
{
	"options":
	{
		"multi_pass_gen": true
	},
	"configs":
	{
		"build": ["build_phase"]
	},
	"phases":
	[
		{
			"id": "%s"
		}
	]
}
''' % phase_id)
ofile.close()
